package com.jrzh.db.migration.sys;

import com.jrzh.framework.migration.BaseMigration;
import com.jrzh.framework.migration.MigrationHelper;
/**
 * 新增数据字典表
 * @author Mr.Shower
 *
 */
public class Migration_6 extends BaseMigration{
	
	private static final String TABLE_NAME = "sys_dictionaries";
	
	@Override
	public void down() {
		log.info("##########回滚Sys模块 Migration_6##########");
		MigrationHelper.dropTable(TABLE_NAME);
	}

	@Override
	public void up() {
		log.info("##########执行Sys模块 Migration_6##########Begin");
		table(TABLE_NAME, "系统字典表", true,
				pk(),
				jrChar("_pid", "父ID", 36),
				jrVarchar("_key", "字典键" , 128),
				jrVarchar("_value", "字典值" , 128),
				jrVarchar("_description", "字典描述" , 512)
		);
		log.info("##########执行Sys模块 Migration_6##########End");
	}

}
